<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Title</title>
</head>
<body>
<script>
/*
 switch:
 
 switch(表达式){
 case 3:
 //代码
 case 4:
 case 5:
 
 }
 */
var a = 39;
switch (a){
    case 1 :
        console.log("1 你好");
        break;
    case 2:
        console.log("2 你好");
        break;
    case 3:
        console.log("3 你好");
        break;
    default:
        console.log("你超出了范围");
        break;

}
</script>
</body>
</html>